import request from "@/utils/request";


export const wxWeblogin = (params) => {
  return request({
    method: "post",
    url: "/app/wxMiniUser/wxWeblogin",
    params,
  });
};
export const getWxMiniUserByOpenId = (params) => {
  return request({
    method: "post",
    url: "/app/wxMiniUser/getWxMiniUserByOpenId",
    params,
  });
};
export const getWxMiniUserByUuid = (params) => {
  return request({
    method: "post",
    url: "/app/wxMiniUser/getWxMiniUserByUuid",
    params,
  });
};
export const getWxMiniUserByUnionid = (params) => {
  return request({
    method: "post",
    url: "/app/wxMiniUser/getWxMiniUserByUnionid",
    params,
  });
};
export const listBanner = (params) => {
  return request({
    method: "post",
    url: "/app/banner/listBanner",
    params,
  });
};
export const getWxUserEnrollInfoByUuid = (params) => {
  return request({
    method: "post",
    url: "/app/wxUserEnrollInfo/getWxUserEnrollInfoByUuid",
    params,
  });
};
export const updateWxUserEnrollInfo = (params) => {
  return request({
    method: "post",
    url: "/app/wxUserEnrollInfo/updateWxUserEnrollInfo",
    params,
  });
};
export const searchByCode = (params) => {
  return request({
    method: "post",
    url: "/app/baseData/searchByCode",
    params,
  });
};
export const enrollTraining = (params) => {
  return request({
    method: "post",
    url: "/app/techTraining/enrollTraining",
    params,
  });
};
export const answerQuestionnaire = (params) => {
  return request({
    method: "post",
    url: "/app/task/answerQuestionnaire",
    params,
  });
};


export const onlineClassDetail = (params) => {
  return request({
    method: "post",
    url: "/app/studentClass/onlineClassDetail",
    params,
  });
};

export const getOnlineClassComment = (params) => {
  return request({
    method: "post",
    url: "/app/studentClass/getOnlineClassComment",
    params,
  });
};

export const onlineClassComment = (params) => {
  return request({
    method: "post",
    url: "/app/studentClass/onlineClassComment",
    params,
  });
};


export const unLoginRecentTraining = (params) => {
  return request({
    method: "post",
    url: "/app/techTraining/unLoginRecentTraining",
    params,
  });
};
export const searchSpecialistInfo = (params) => {
  return request({
    method: "post",
    url: "/app/specialistInfo/searchSpecialistInfo",
    params,
  });
};
export const searchHotOnlineClass = (params) => {
  return request({
    method: "post",
    url: "/app/onlineClass/searchHotOnlineClass",
    params,
  });
};
export const searchQuestionPage = (params) => {
  return request({
    method: "post",
    url: "/app/farmingQuestion/searchQuestionPage",
    params,
  });
};
export const searchAchievement = (params) => {
  return request({
    method: "post",
    url: "/app/achievement/searchAchievement",
    params,
  });
};
export const searchBulletin = (params) => {
  return request({
    method: "post",
    url: "/app/bulletin/searchBulletin",
    params,
  });
};
export const getAchievementByUuid = (params) => {
  return request({
    method: "post",
    url: "/app/achievement/getAchievementByUuid",
    params,
  });
};
export const searchHeadTeacher = (params) => {
  return request({
    method: "post",
    url: "/app/study/searchHeadTeacher",
    params,
  });
};
export const listTrainingPhoto = (params) => {
  return request({
    method: "post",
    url: "/app/study/listTrainingPhoto",
    params,
  });
};
export const saveTrainingStudentLeave = (params) => {
  return request({
    method: "post",
    url: "/app/studentLeave/saveTrainingStudentLeave",
    params,
  });
};
export const getTrainingDetail = (params) => {
  return request({
    method: "post",
    url: "/app/techTraining/getTrainingDetail",
    params,
  });
};
export const searchQuestionnaire = (params) => {
  return request({
    method: "post",
    url: "/app/task/searchQuestionnaire",
    params,
  });
};
export const trainingList = (params) => {
  return request({
    method: "post",
    url: "/app/studentLeave/trainingList",
    params,
  });
};

export const studentLeaveList = (params) => {
  return request({
    method: "post",
    url: "/app/studentLeave/studentLeaveList",
    params,
  });
};
export const messageList = (params) => {
  return request({
    method: "post",
    url: "/app/notice/messageList",
    params,
  });
};

export const saveStudentProject = (params) => {
  return request({
    method: "post",
    url: "/app/studentProject/saveStudentProject",
    params,
  });
};
export const updateStudentProject = (params) => {
  return request({
    method: "post",
    url: "/app/studentProject/updateStudentProject",
    params,
  });
};

export const getByWxUserUuid = (params) => {
  return request({
    method: "post",
    url: "/app/studentProject/getByWxUserUuid",
    params,
  });
};
export const getTxCosCredential = (params) => {
  return request({
    method: "post",
    url: "/app/file/getTxCosCredential",
    params,
  });
};
export const myStudy = (params) => {
  return request({
    method: "post",
    url: "/app/study/myStudy",
    params,
  });
};
export const presentTraining = (params) => {
  return request({
    method: "post",
    url: "/app/study/presentTraining",
    params,
  });
};
// 记录学习
export const onlineClassStudy = (params) => {
  return request({
    method: "post",
    url: "/app/studentClass/onlineClassStudy",
    params,
  });
};
// 更新学习时间
export const onlineClassStudyPosition = (params) => {
  return request({
    method: "post",
    url: "/app/studentClass/onlineClassStudyPosition",
    params,
  });
};
// 农机问答提问
export const askQuestion = (params) => {
  return request({
    method: "post",
    url: "/app/farmingQuestion/askQuestion",
    params,
  });
};

// 搜索
export const searchByType = (params) => {
  return request({
    method: "post",
    url: "/app/search/searchByType",
    params,
  });
};
// 新闻详情
export const getNewByUuid = (params) => {
  return request({
    method: "post",
    url: "/app/new/getNewByUuid",
    params,
  });
};
// 新闻列表
export const searchNew = (params) => {
  return request({
    method: "post",
    url: "/app/new/searchNew",
    params,
  });
};

// 问答详情
export const getQuestionAnswer = (params) => {
  return request({
    method: "post",
    url: "/app/farmingQuestion/getQuestionAnswer",
    params,
  });
};

// 我的课程
export const searchMyOnlineClass = (params) => {
  return request({
    method: "post",
    url: "/app/online/searchMyOnlineClass",
    params,
  });
};
// 门户链接列表
export const listPortalUrl = (params) => {
  return request({
    method: "post",
    url: "/applet/portalUrl/listPortalUrl",
    params,
  });
};

// 根据wxUserUuid查询证书
export const getByWxUserUuids = (params) => {
  return request({
    method: "post",
    url: "/app/certificate/getByWxUserUuid",
    params,
  });
};
